<?php
/**
 * 菜单修改参数
 *
 * @author: WangBin
 * @date: 2021/7/26
 * @mail: <849850352@qq.com>
 */
namespace App\Params\Backend;

use App\Params\Param;

class MenuUpdateParam extends Param
{
    public $menu_id;
    public $menu_name;
    public $url;
    public $icon;
    public $is_active = 1;
    public $intro;
    public $level;
    public $sort_num;
    public $parent_id;

    public function rules()
    {
        return [
            'menu_name' => 'required|string',
            'is_active' => 'boolean',
            'level' => 'in:1,2',
            'parent_id' => 'integer'
        ];
    }

    /**
     * @return mixed
     */
    public function getId()
    {
        return $this->menu_id;
    }

    /**
     * @param mixed $id
     */
    public function setId($id): void
    {
        $this->menu_id = $id;
    }

    /**
     * @return mixed
     */
    public function getMenuName()
    {
        return $this->menu_name;
    }

    /**
     * @param mixed $menu_name
     */
    public function setMenuName($menu_name): void
    {
        $this->menu_name = $menu_name;
    }

    /**
     * @return mixed
     */
    public function getUrl()
    {
        return $this->url;
    }

    /**
     * @param mixed $url
     */
    public function setUrl($url): void
    {
        $this->url = $url;
    }

    /**
     * @return mixed
     */
    public function getIcon()
    {
        return $this->icon;
    }

    /**
     * @param mixed $icon
     */
    public function setIcon($icon): void
    {
        $this->icon = $icon;
    }

    /**
     * @return mixed
     */
    public function getIsActive()
    {
        return $this->is_active;
    }

    /**
     * @param mixed $is_active
     */
    public function setIsActive($is_active): void
    {
        $this->is_active = $is_active;
    }

    /**
     * @return mixed
     */
    public function getIntro()
    {
        return $this->intro;
    }

    /**
     * @param mixed $intro
     */
    public function setIntro($intro): void
    {
        $this->intro = $intro;
    }

    /**
     * @return mixed
     */
    public function getLevel()
    {
        return $this->level;
    }

    /**
     * @param mixed $level
     */
    public function setLevel($level): void
    {
        $this->level = $level;
    }

    /**
     * @return mixed
     */
    public function getSortNum()
    {
        return $this->sort_num;
    }

    /**
     * @param mixed $sort_num
     */
    public function setSortNum($sort_num): void
    {
        $this->sort_num = $sort_num;
    }

    /**
     * @return mixed
     */
    public function getParentId()
    {
        return $this->parent_id;
    }

    /**
     * @param mixed $parent_id
     */
    public function setParentId($parent_id): void
    {
        $this->parent_id = $parent_id;
    }
}